<!DOCTYPE html>
<html lang="zh_CN" xmlns:th="http://www.thymeleaf.org"
      xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<meta charset="utf-8">
<head th:include="include::header"></head>
<style>
    .last-option{
        color: #ff7800;
    }
</style>
<!--<script src="/js/plugins/layui/layui.all.js"></script>&lt;!&ndash; 最新版本 20190421 &ndash;&gt;-->
<body class="gray-bg">
<div class="wrapper wrapper-content ">
    <div class="col-sm-12">
        <div class="ibox">
            <div class="ibox-body">
                <div id="orderToolbar" role="group" class="container">

                    <div class="row" >
                        <button shiro:hasPermission="sys:role:add" type="button"
                                class="btn btn-primary" onclick="add()">
                            <i class="fa fa-plus" aria-hidden="true"></i>录单
                        </button>
                        <button shiro:hasPermission="sys:role:add" type="button"
                                class="btn btn-primary" onclick="importExcel()">
                            <i class="fa fa-cloud-upload" aria-hidden="true"></i>导入
                        </button>
                        <button shiro:hasPermission="sys:role:batchRemove" type="button"
                                class="btn btn-success" onclick="batchOrder()">
                            <i class="fa fa-check" aria-hidden="true"></i>下单
                        </button>
                        <button shiro:hasPermission="sys:role:batchRemove" type="button"
                                class="btn btn-success" onclick="exportExcel()">
                            <i class="fa fa-check" aria-hidden="true"></i>导出
                        </button>
                        <button type="button"
                                class="btn btn-success" onclick="batchPrint()">
                            <i class="fa fa-print" aria-hidden="true"></i>打印
                        </button>

                        <!--<div class="col-sm-1">
                            <button class="btn btn-success" onclick="reLoad()">查询</button>
                        </div>-->
                    </div>
                    <br/>
                    <div class="row" >
                        <div class="col-sm-12">
                            <div class="col-sm-3">
                                <div class="input-group">
                                    <span class="input-group-addon" style="background-color:#d4d4d4" >签收状态</span>
                                    <select class="form-control" id="lgs_status" name="lgs_status">
                                        <option value="">全部</option>
                                        <option value="1">未下单</option>
                                        <option value="3">待提货</option>
                                        <option value="5">已发货</option>
                                        <option value="7">已签收</option>
                                    </select>
                                </div>
                            </div>

                            <div class="col-sm-3">
                                <div class="input-group">
                                    <span class="input-group-addon" style="background-color:#d4d4d4" >物流公司</span>
                                    <select class="form-control" id="company_list" name="company" th:field="${companyCheckBoxList}" th:value="${companyCheckBoxList}">
                                        <option value="">全部</option>
                                        <option th:each="company : ${companyCheckBoxList}"
                                                th:value="${company.value}" th:text="${company.name}">XXX</option>
                                    </select>
                                </div>
                            </div>

                            <div class="col-sm-3">
                                <div class="input-group">
                                    <span class="input-group-addon" style="background-color:#d4d4d4" >下单日期</span>
                                    <input id="datePicker" name="datePicker" type="text" class="form-control" placeholder="全部">
                                    <input id="startDate" name="startDate" type="hidden">
                                    <input id="endDate" name="endDate" type="hidden">
                                </div>
                            </div>
                        </div>
                    </div>


                </div>
                <table id="orderTable" data-mobile-responsive="true">
                </table>

                <div class="tabbable" id="tabs-122507">
                    <ul class="nav nav-tabs">
                        <li>
                            <a href="#panel-detail" data-toggle="tab" id="panelDetail">订单详情</a>
                        </li>
                        <li class="active">
                            <a href="#panel-track" data-toggle="tab" id="panelTrack">跟踪信息</a>
                        </li>
                    </ul>
                    <div class="tab-content">
                        <div class="tab-pane" id="panel-detail">
                            <div class="row">
                                <div class="col-sm-2">
                                    <span class="input-group-addon">产品评分：</span>
                                </div>
                                <div class="col-sm-4">
                                    <!--<fieldset class="layui-elem-field layui-field-title" style="margin-left: 30px;">-->
<!--&lt;!&ndash;                                        <legend>评分</legend>&ndash;&gt;-->
                                    <!--</fieldset>-->
                                    <div id="gradeScore"></div>
                                </div>
                                <div class="col-sm-2">
                                    <span class="input-group-addon">物流评分：</span>
                                </div>
                                <div class="col-sm-4">
                                    <div id="lgsScore"></div>
                                </div>
                            </div>

                            <div th:include="lgs/orderDetail::orderDetail"></div>
                            <!-- 第7行 -->
                            <div class="row">
                                <div class="col-sm-12">
                                    <div class="input-group">
                                        <span class="input-group-addon">&ensp;评&ensp;&ensp;价&ensp;：</span>
                                        <input id="grade_content" type="text" class="form-control" placeholder="无" readonly="true">
                                    </div>
                                </div>
                            </div>
                            <!-- 第8行 -->
                            <div class="row" style="display: none">
                                <div class="col-sm-12">
                                    <div class="input-group">
                                        <span class="input-group-addon">物流评价：</span>
                                        <input id="lgs_content" type="text" class="form-control" placeholder="无" readonly="true">
                                    </div>
                                </div>
                            </div>
                            <!-- 第9行 -->
                            <br/>
                            <fieldset class="layui-elem-field layui-field-title" style="margin-top: 10px;">
                                评价图片
                            </fieldset>
                            <div class="row">
                                <div class="col-sm-12">
                                    <div id="screenshots" class="col-sm-12">

                                    </div>
                                </div>
                            </div>
                            <!-- 第10行 -->
                            <br/>
                            <fieldset class="layui-elem-field layui-field-title" style="margin-top: 10px;">
                                回单图片
                            </fieldset>
                            <div class="row">
                                <div class="col-sm-12">
                                    <div id="receipt" class="col-sm-12">

                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="tab-pane active" id="panel-track">
                            <!--<p>-->
                                <!--Howdy, I'm in Section 2.-->
                            <!--</p>-->
                            <div th:include="lgs/orderTrack::orderTrack"></div>

                        </div>
                    </div>
                </div>

            </div>
        </div>
    </div>
    <!--shiro控制bootstraptable行内按钮看见性 来自bootdo的创新方案 -->
    <div>
        <script type="text/javascript">
            var s_edit_h = 'hidden';
            var s_remove_h = 'hidden';
        </script>
    </div>
    <div shiro:hasPermission="sys:role:edit">
        <script type="text/javascript">
            s_edit_h = '';
        </script>
    </div>
    <div shiro:hasPermission="sys:role:remove">
        <script type="text/javascript">
            var s_remove_h = '';
        </script>
    </div>

</div>

<div style="visibility:hidden;">
    <div id="printDetailDiv">
        <table style="margin: 20px 30px; border-collapse:collapse;width:809px;">
            <thead>
            <tr>
                <th colspan="6" style="text-align: center; padding:10px;"><strong>物流运单</strong></th>
            </tr>
            </thead>
            <tbody>
            <tr>
                <td height="30px" width="90px">物流公司：</td>
                <td id="lgs_company_nm" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
                <td height="30px" width="90px">货物名称：</td>
                <td id="goods_name" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
                <td height="30px" width="90px">运输方式：</td>
                <td id="transport_mode_nm" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
            </tr>
            <tr>
                <td height="30px" width="90px">发货件数：</td>
                <td id="delivery_qty" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
                <td height="30px" width="90px">客户名称：</td>
                <td id="customer_name" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
                <td height="30px" width="90px">价值声明：</td>
                <td id="value_statement" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
            </tr>
            <tr>
                <td height="30px" width="90px">收货人：</td>
                <td id="consignee" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
                <td height="30px" width="90px">交付方式：</td>
                <td id="delivery_method_nm" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
                <td height="30px" width="90px">收货电话：</td>
                <td id="consignee_phone" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
            </tr>
            <tr>
                <td height="30px" width="90px">产品尺寸：</td>
                <td id="product_size" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
                <td height="30px" width="90px">物流运单号：</td>
                <td id="lgs_track_number" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
                <td height="30px" width="90px">雄帝运单号：</td>
                <td id="xd_track_number" height="30px" width="178px"
                    style="background-color:rgb(238, 238, 238)">无
                </td>
            </tr>
            <tr>
                <td colspan="1">收货地址：</td>
                <td colspan="5" id="consignee_address" style="background-color:rgb(238, 238, 238)">无</td>
            </tr>
            <tr>
                <td colspan="1">备注：</td>
                <td colspan="5" id="remark" style="background-color:rgb(238, 238, 238)">无</td>
            </tr>
            </tbody>
        </table>
        <!--<span style="position:fixed;left:40px;">发货人：</span><span style="position:fixed;left:100px;" id="sender"></span>-->
        <!--<span style="position:fixed;left:440px;">收货人：</span>-->
    </div>
</div>

<div th:include="include::footer"></div>
<script type="text/javascript" src="/js/appjs/lgs/order/order.js">

</script>
</body>

</html>